package service

import (
	sqlc "bgs/db/sqlc"
	"context"
)

func (s *AfterSaleServiceImp) ListAfterSaleDetailPtrsByAfterSaleID(ctx context.Context, q *sqlc.Queries, afterSaleID int64) (afterSaleDetailPtrs []*sqlc.AfterSaleDetail, err error) {
	afterDetails, err := q.ListNormalAfterSaleDetailsByAfterSaleID(ctx, afterSaleID)
	if err != nil {
		return
	}
	afterSaleDetailPtrs = s.MapAfterSaleDetailEntityToPtr(afterDetails)
	return
}
